package hcn.protocol.ods.casehistory;

import hcn.util.validation.InvokeType;
import hcn.util.validation.ValidationAnnotaion;
import lombok.*;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * @Author: zhusm@bsoft.com.cn
 *
 * @Description: 病历复印接收参数集
 *
 * @Create: 2019-06-17 15:41
 **/
@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
@ToString
public class CaseHistoryRequestBean {

    private Integer copyApplyRecordId;
    @ValidationAnnotaion(minLength =1,maxLength = 18,errorDescription = "姓名格式不正确")
    @ValidationAnnotaion.NotNull(errorDescription = "姓名不能为空")
    private String patientName;//患者姓名
    @ValidationAnnotaion.NotNull(errorDescription = "患者证件卡类型不能为空")
    private String patientIdentityCardType;//患者证件卡类型
    @ValidationAnnotaion.NotNull(errorDescription = "患者证件卡号不能为空")
    private String patientIdentityCardNumber;//患者证件号

    private String patientTelephone;//患者手机号

    private String bltype="1";//病历类型

    private String blNum="";//病历编号

    private List<PictureInfoList> copyApplyPictureInfoList;//图片地址数组
    private List<ContentList> copyContentList;//复印内容
    private List<UseList> copyUseList;//复印内容
    @ValidationAnnotaion.NotNull(errorDescription = "配送方式不能为空")
    private String deliveryModeCode;//支付模式  0:在线支付 1：到付
    @ValidationAnnotaion(type = InvokeType.NUMBER,minValue = 1,errorDescription = "份数至少为1份")
    private int copyNumber;//复印份数
    private String inDate;//入院日期
    private String outDate;//出院日期
    private String payModeName;//支付方式
    @ValidationAnnotaion.NotNull(errorDescription = "支付方式不能为空")
    private int payModeCode;//支付方式
    //住院相关
    private String hospitalizationNumber;//住院号
    private String hospitalCode;//机构id
    private String hospitalName;//机构名称
    @ValidationAnnotaion.NotNull(errorDescription = "就诊科室不能为空")
    private String visitingDepartmentName;//就诊科室
    private String visitingSerialNumber;//就诊流水号
//    private String invoiceNumber;//发票号
    //收货地址相关
    @ValidationAnnotaion.NotNull(errorDescription = "邮寄地址不能为空")
    private String consigneeDetailedAddress;
    @ValidationAnnotaion.NotNull(errorDescription = "申请类型不能为空")
    private String applicantType;//申请类型代码 1：本人申请2：他人代办
    private String applicantIdentityCardType;//申请人证件类型
    private String applicantIdentityCardNumber;//申请人证件号码(预留，目前为空)
    private String consigneeTelephone;//收件人手机号
    private String remarkInfo;//备注

    @Data
    @AllArgsConstructor
    @NoArgsConstructor
    @ToString
    public static class ContentList{
        private String copyContentCode;
        @ValidationAnnotaion.NotNull(errorDescription = "复印内容不能为空")
        private String copyContentName;//用途名称
    }
    @Data
    @AllArgsConstructor
    @NoArgsConstructor
    @ToString
    public static class PictureInfoList{
        @ValidationAnnotaion.NotNull(errorDescription = "证件图片不能为空")
        private String identityCardPictureAddress;//证件图片地址
        @ValidationAnnotaion.NotNull(errorDescription = "证件类型不能为空")
        private String pictureClassify;//图片分类
    }
    @Data
    @AllArgsConstructor
    @NoArgsConstructor
    @ToString
    public static class UseList{
        private String copyUseCode;//用途代码
        @ValidationAnnotaion.NotNull(errorDescription = "用途不能为空")
        private String copyUseName;//用途名称
    }
}
